<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>flex布局1</title>
    <style>
        body {
            padding: 0;
            margin: 0;
        }
        
        .box {
            height: 160px;
            width: 400px;
            padding: 0;
            background-color: aquamarine;
            display: flex;
            /*排序方向*/
            flex-direction: row;
            /*换行方式*/
            flex-wrap: wrap-reverse;
        }
        
        .div-item {
            width: 60px;
            height: 60px;
            margin: 10px;
            background-color: #eeeeee;
        }
    </style>
</head>
<div class="box">
    <div class="div-item"></div>
    <div class="div-item"></div>
    <div class="div-item"></div>
    <div class="div-item"></div>
    <div class="div-item"></div>
    <div class="div-item"></div>
    <div class="div-item"></div>
    <div class="div-item"></div>
    <div class="div-item"></div>
</div>

<body>

    <script>
    </script>
</body>

</html>